package com.cow.controller;

import com.cow.service.ReturnGoodsService;
import com.cow.util.general.CommonResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;
import java.util.Map;

@RestController
@RequestMapping("/returnGoods")
public class ReturnGoodsController {
    @Autowired
    private ReturnGoodsService returnGoodsService;

    @GetMapping("/findReturnInfo")
    public CommonResult findReturnInfo(String userNumber){
        List<Map<String,Object>> mapList = returnGoodsService.getReturnGoodsByUserNumber(userNumber);
        return CommonResult.success("退货信息查询成功",mapList);
    }
}
